package com.xhwl.centiotdata.pushtrigger.alarm;

import com.xhwl.centiotdata.handler.alarm.impl.TongTongReceiveHandler;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

import javax.servlet.http.HttpServletResponse;

/**
 * @author masiyuan
 * @since 2023年05月16日 09:04
 */

@Slf4j
@RestController
public class TongTongReceiveController {

    @Autowired
    private TongTongReceiveHandler tongTongReceiveHandler;

    @PostMapping("/alarm-receive/tongtong-receive")
    public void tongTongReceive(@RequestBody String receiveContent, HttpServletResponse response) {
        tongTongReceiveHandler.tongTongAlarmReceive(receiveContent, response);
    }

}
